1. Field of the Invention
Methods and apparatuses consistent with the present invention relate to coding and decoding of an audio signal, and more particularly, to efficient coding and decoding of birth mode sinusoids.
2. Description of the Related Art
Parametric coding is a method of coding an audio signal according to certain parameters. The parametric coding is used for Moving Picture Experts Group-4 (MPEG-4) standards.
FIG. 1 is a diagram for describing a related art parametric coding method. The parametric coding method analyzes and parameterizes an input audio signal.
Referring to FIG. 1, audio reading and filtering are performed on the input audio signal. Transient analysis, sinusoidal analysis, and noise analysis are performed on each region of the input audio signal, thereby extracting parameters of audio components of each region. The transient analysis corresponds to very dynamic audio variations. The sinusoidal analysis corresponds to deterministic audio variations. The noise analysis corresponds to stochastic or non-deterministic audio variations.
Bit-stream formatting is performed on the extracted parameters.
After performing the sinusoidal analysis, extracted sinusoids are tracked for adaptive differential pulse code modulation (ADPCM) coding or differential pulse code modulation (DPCM) coding. The tracking searches for sinusoids of a current frame which are continued from sinusoids of a previous frame and set correspondence therebetween. Sinusoids of the current frame which can be tracked from the sinusoids of the previous frame are referred to as continuation mode sinusoids. The continuation mode sinusoids may be efficiently coded by using the sinusoids of the previous frame which correspond to the continuation mode sinusoids.
On the other hand, sinusoids of the current frame which are not tracked from the sinusoids of the previous frame are referred to as birth mode sinusoids. The birth mode sinusoids are newly generated in the current frame instead of being continued from the sinusoids of the previous frame. In general, the birth mode sinusoids cannot be coded by using the sinusoids of the previous frame and thus a large number of bits are required for coding.
Accordingly, a method of reducing the number of bits is required to code the birth mode sinusoids.
FIG. 2 is a flowchart of a related art audio coding method.
Referring to FIG. 2, sinusoidal analysis is performed on an input audio signal and sinusoids, also referred to as partials, are extracted. The extracted sinusoids are tracked by using information on the sinusoids in operation S100. The tracking searches for sinusoids of a current frame which are continued from sinusoids of a previous frame and set correspondence therebetween. During the tracking of the sinusoids, continuation mode sinusoids are coded.
Birth mode sinusoids from among the sinusoids of the current frame are sorted in ascending order of frequency in operation S110. Here, the number of birth mode sinusoids is assumed to be n.
The birth mode sinusoids are input one by one in order of frequency from a birth mode sinusoid having a lower frequency to a birth mode sinusoid having a higher frequency in order to perform following operations in operation S120. Here, a frequency and an amplitude of a birth mode sinusoid are respectively represented as f(i) and a(i).
1. The amplitude a(i) is quantized in operation S130. The quantized amplitude is represented as q_a(i).
2. It is determined whether the birth mode sinusoid has the lowest frequency or not in operation S140. If it is determined that the birth mode sinusoid has the lowest frequency, the quantized amplitude q_a(i) is absolutely coded in operations S150 and S170.
3. If it is determined that the birth mode sinusoid does not have the lowest frequency, a difference between the quantized amplitude q_a(i) of the current birth mode sinusoid and a quantized amplitude q_a(i-1) of a previous birth mode sinusoid is calculated in operation S160, and the difference is coded in operation S170.
FIG. 3 is a graph of an example to which the audio coding method of FIG. 2 is applied.
Referring to FIG. 3, sinusoids of a current frame are p30, p31, p32, p33, p34, p35, and p36 and continuation mode sinusoids are P31, p32, p34, and p36. The continuation mode sinusoid p31 is continued from a previous sinusoid p20, the continuation mode sinusoid p32 is continued from a previous sinusoid p21, the continuation mode sinusoid p34 is continued from a previous sinusoid p22, and the continuation mode sinusoid p36 is continued from a previous sinusoid p23.
On the other hand, birth mode sinusoids are p30, p33, and p35.
If the related art audio coding method of FIG. 2 is applied here, an amplitude a30 of the birth mode sinusoid p30 is absolutely coded. However, with regard to an amplitude a33 of the birth mode sinusoid p33, a difference diff33=a33−a30 is calculated and coded. Also, with regard to an amplitude a35 of the birth mode sinusoid p35, a difference diff35=a35−a33 is calculated and coded.
The present invention provides an efficient coding method by addressing a problem of the related art method, which is that difference coding is performed between birth mode sinusoids.
In an audio signal, sinusoids having frequencies close to each other also have similar amplitudes. Accordingly, when the difference coding is performed on an amplitude of a sinusoid, it is advantageous to calculate an amplitude difference from a sinusoid having a close frequency. However, referring back to FIG. 2, the difference coding is performed between the birth mode sinusoids so that coding efficiency is greatly reduced if a frequency difference therebetween is large. Referring back to FIG. 3, when the birth mode sinusoid p33 is coded, due to a large frequency difference between the birth mode sinusoids p30 and p33, the amplitude difference therebetween may also be large. In this case, if the amplitude difference is coded, the coded value has a large number of bits. For example, if the amplitude a33 is 3 bits and the amplitude a30 is 10 bits, the amplitude difference is larger than the amplitude a33.
Difference coding is performed because the number of bits required to code is less than when absolute coding is performed, if the amplitudes of the sinusoids have correlations therebetween. However, in the above example, absolute coding may be more efficient.
The present invention suggests an efficient method of further reducing the number of bits required to code birth mode sinusoids by using sinusoids having large correlations therebetween.